Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feat] 메인홈 약속 조회 관련 API 구현 #47

Merged
merged 6 commits into from
Jul 12, 2024
Merged

Conversation

chaewonni
Copy link
Member

@chaewonni chaewonni commented Jul 12, 2024

Related issue 🛠

Work Description ✏️

  • 메인홈 약속 조회 관련 API들을 구현합니다. (오늘 가장 가까운 약속 조회, 다가올 약속 목록 조회)

Uncompleted Tasks 😅

  • N/A

To Reviewers 📢

@Query("SELECT p FROM Participant pt " +
"JOIN pt.member m " +
"JOIN pt.promise p " +
"WHERE m.user.id = :userId " +
"AND p.time >= :startOfDay " +
"AND p.time < :startOfNextDay " +
"AND p.time > CURRENT_TIMESTAMP " +
"AND p.isCompleted = false " +
"ORDER BY p.time ASC, p.createdAt ASC")
Page<Promise> findNextPromiseByUserId(Long userId, LocalDateTime startOfDay, LocalDateTime startOfNextDay, Pageable pageable);

자기가 속한 '모임의 모든 약속'이 아닌, 자기가 속한 약속들만 가져오도록 했습니다.
쿼리 한 번 확인해주시면 감사하겠습니당!

@tkdwns414 tkdwns414 merged commit b4132ac into develop Jul 12, 2024
1 check passed
@tkdwns414 tkdwns414 deleted the feat/40 branch July 12, 2024 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[feat] 메인홈 약속 조회 관련 API 구현
2 participants